<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <title>Title</title>
</head>
<body>
<button id="btn1">img1</button>
<button id="btn2">img2</button>
<br>
<img src="https://image.yunyingpai.com/wp/2019/01/XWKhOwE8nestNSSZq0Uv.jpeg" alt="">
</body>
<script>
  var btn1 = document.querySelector('#btn1');
  var btn2 = document.querySelector('#btn2');
  var img = document.querySelector('img');

  btn1.onclick = function () {
    img.src = 'https://image.yunyingpai.com/wp/2019/01/XWKhOwE8nestNSSZq0Uv.jpeg'
  }
  btn2.onclick = function () {
    img.src = 'https://image.yunyingpai.com/wp/2019/01/O0vPhSvmirhl5zojMyfB.png';

  }
</script>
</html>